-
Notifications
You must be signed in to change notification settings - Fork 839
[Dispatch Creation] Don't fuse if there are no common parallel loops #22819
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Dispatch Creation] Don't fuse if there are no common parallel loops #22819
Conversation
Signed-off-by: Ian Wood <ianwood@u.northwestern.edu>
Signed-off-by: Ian Wood <ianwood@u.northwestern.edu>
kuhar
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @IanWood1
compiler/src/iree/compiler/DispatchCreation/test/dispatch_linalg_ext_fusion.mlir
Outdated
Show resolved
Hide resolved
Signed-off-by: Ian Wood <ianwood@u.northwestern.edu>
Signed-off-by: Ian Wood <ianwood@u.northwestern.edu>
|
CLIP dispatch count increased because this now gets split into 2 dispatches https://gist.github.com/IanWood1/73971d57bd8243f491291bfa4d4b8e36 |
Signed-off-by: Ian Wood <ianwood@u.northwestern.edu>
MaheshRavishankar
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The increase in clip dispatch is fine. This shouldnt have fused to start with.
Fixes golden dispatch counts that were not updated in #22819 because the PR wasn't run with `ci-extra: test_torch`. ci-extra: test_torch Signed-off-by: Ian Wood <ianwood@u.northwestern.edu>
…22819) This change prevents fusion when the root op does not share parallel loops with its producers or consumers. Because we require the iteration space of reduction ops to match exactly, this can only occur when the non-root is all parallel. And when the non-root is all parallel, there will only ever be no common parallel loops if the root has no parallel loops. `newMap` is the mapping from the root op's to the non-root op's parallel loops. If there aren't any dims in the output, then there is no mapping between the loops. This preserves the old behavior introduced by #12661. Related #22815 --------- Signed-off-by: Ian Wood <ianwood@u.northwestern.edu> Signed-off-by: Keshav Vinayak Jha <keshavvinayakjha@gmail.com>
Fixes golden dispatch counts that were not updated in #22819 because the PR wasn't run with `ci-extra: test_torch`. ci-extra: test_torch Signed-off-by: Ian Wood <ianwood@u.northwestern.edu> Signed-off-by: Keshav Vinayak Jha <keshavvinayakjha@gmail.com>
This change prevents fusion when the root op does not share parallel loops with it's producers or consumers. Because we require the iteration space of reduction ops to match exactly, this can only occur when the non-root is all parallel. And when the non-root is all parallel, there will only ever be no common parallel loops if the root has no parallel loops.
newMapis the mapping from the root op's to the non-root op's parallel loops. If there aren't any dims in the output, then there is no mapping between the loops.This preserves the old behavior introduced by #12661.
Related #22815